/*
 *  Copyright (C) 2010 Glauco
 * 
 *  This program is free software: you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation, either version 3 of the License, or
 *  (at your option) any later version.
 * 
 *  This program is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 * 
 *  You should have received a copy of the GNU General Public License
 *  along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

package org.balisunrise.builder;

import org.balisunrise.annotation.util.PanelUtilities;
import org.balisunrise.common.EntityPanel;

/**
 * Esta Inteface é responsável pela construção dos paineis das entidades.
 *
 * @author Glauco
 */
public interface EntityPanelBuilder {

    /**
     * Cria um painel a partir de uma classe de uma entidade e o alias para
     * construção do Painel.<br>
     * Este método cria os campos (PanelField) associados ao painel.
     *
     * @param entityClass Classe da entidade.
     * @param alias Alias para construção do painel.
     * @return Um EntityPanel.
     */
    public EntityPanel create(Class entityClass, String alias)
            throws BuilderException;

    /**
     * Cria um painel a partir de um PanelUtilities.
     * Este método cria os campos (PanelField) associados ao painel.
     *
     * @param panelUtilities Utilitário para construir o painel.
     * @return Um EntityPanel.
     */
    public EntityPanel create(PanelUtilities panelUtilities)
            throws BuilderException;
}
